import {
	http
} from "../utils/request";

const base = "http://rke.xjznpt.cn/api/MobileApi"

const mineApi = {
	getMyRoomInfo(data) {
		return http({
			url: `${base}/GetMyRoomInfo`,
			method: "post",
			data
		})
	},
	getMyFamilyRoom(data) {
		return http({
			url: `${base}/GetMyFamilyRoom`,
			method: "post",
			data
		})
	},
	getMyFamilyList(data) {
		return http({
			url: `${base}/GetMyFamilyList`,
			method: "post",
			data
		})
	},
	sendErrlog(data) {
		return http({
			url: `/app/sys/errlog`,
			method: "post",
			data
		})
	},
	// 我的家人
	createHouse(data) {
		return http({
			url: `${base}/CreateHouse`,
			method: "post",
			data
		})
	},
	delHouseById(data) {
		return http({
			url: `${base}/delHouseById`,
			method: "post",
			data
		})
	},
	uploadImage() {
		return `${base}/UploadImage`;
	},
	addFace(data) {
		return http({
			url: `${base}/AddHouseRegFace`,
			method: "post",
			data
		})
	},
	delFace(data) {
		return http({
			url: `${base}/delHouseFace`,
			method: "post",
			data
		})
	},
	// 个人信息修改
	updateUser(data) {
		return http({
			contentType: "application/x-www-form-urlencoded",
			url: `/app/user/updUser`,
			method: "post",
			data
		})
	},
	uploadPic(data) {
		return http({
			url: `/app/user/uploadPic`,
			method: "post",
			data
		})
	},
	changePwd(data) {
		return http({
			url: `http://accountv4.xjznpt.cn/app/v1/Account/ChangePassword`,
			method: "post",
			data
		})
	},
}

export default mineApi;